<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML Strict//EN">
<HTML>
<HEAD>
<TITLE>SX</TITLE>
</HEAD>
<BODY>
<H1>SX</H1>
<H4>
An SGML System Conforming to
International Standard ISO 8879 --<BR>
Standard Generalized Markup Language
</H4>
<H2>
SYNOPSIS
</H2>
<P>
<CODE>sx</CODE>
[
<CODE>-Cehilprvx</CODE>
]
[
<CODE>-b<VAR>encoding</VAR></CODE>
]
[
<CODE>-c<VAR>catalog_file</VAR></CODE>
]
[
<CODE>-D<VAR>directory</VAR></CODE>
]
[
<CODE>-f<VAR>file</VAR></CODE>
]
[
<CODE>-w<VAR>warning_type</VAR></CODE>
]
[
<CODE>-x<VAR>xml_output_option</VAR></CODE>
]
<CODE><VAR>sysid...</VAR></CODE>
<H2>DESCRIPTION</H2>
<P>
SX converts SGML to XML.
SX parses and validates the SGML document contained in
<CODE><VAR>sysid...</VAR></CODE>
and writes an equivalent XML document to the standard output.
SX will warn about SGML constructs which have no XML equivalent.
<P>
The following options are available:
<DL>
<DT>
<CODE>-b<VAR>encoding</VAR></CODE>
<DD>
Use <A HREF="charset.htm#encodings"><CODE><VAR>encoding</VAR></CODE></A> for output.
By default SX uses UTF-8.
<DT>
<CODE>-c<VAR>file</VAR></CODE>
<DD>
Use the catalog entry file
<CODE><VAR>file</VAR></CODE>.
<DT>
<CODE>-C</CODE>
<DD>
This has the same effect as in <A HREF="nsgmls.htm#optC">nsgmls</A>.
<DT>
<CODE>-D<VAR>directory</VAR></CODE>
<DD>
Search
<CODE><VAR>directory</VAR></CODE>
for files specified in system identifiers.
This has the same effect as in <A HREF="nsgmls.htm#optD">nsgmls</A>.
<DT>
<CODE>-e</CODE>
<DD>
Describe open entities in error messages.
<DT>
<CODE>-f<VAR>file</VAR></CODE>
<DD>
Redirect errors to
<CODE><VAR>file</VAR></CODE>.
This is useful mainly with shells that do not support redirection
of stderr.
<DT>
<CODE>-i<VAR>name</VAR></CODE>
<DD>
This has the same effect as in <A HREF="nsgmls.htm#opti">nsgmls</A>.
<DT>
<CODE>-v</CODE>
<DD>
Print the version number.
<DT>
<CODE>-w<VAR>type</VAR></CODE>
<DD>
Control warnings and errors according to
<CODE><VAR>type</VAR></CODE>.
This has the same effect as in <A HREF="nsgmls.htm#optw">nsgmls</A>.
<DT>
<CODE>-x<VAR>xml_output_option</VAR></CODE>
<DD>
Control the XML output according to the value of
<CODE><VAR>xml_output_option</VAR></CODE> as follows:
<DL>
<DT>
<CODE>no-nl-in-tag</CODE>
<DD>
Don't use newlines inside start-tags.
Usually SX uses newlines inside start-tags so as to reduce the
probability of excessively long lines.
<DT>
<CODE>id</CODE>
<DD>
Output attribute declarations for ID attributes.
<DT>
<CODE>notation</CODE>
<DD>
Output declarations for notations.
<DT>
<CODE>ndata</CODE>
<DD>
Output declarations for external data entities.
XML requires these to be NDATA.
SX will warn about CDATA and SDATA external data entities and
output them as NDATA entities.
<DT>
<CODE>cdata</CODE>
<DD>
Use XML CDATA sections for CDATA marked sections and for elements with a
declared content of CDATA.
<DT>
<CODE>comment</CODE>
<DD>
Output comment declarations.  Comment declarations in the DTD will not
be output.
<DT>
<CODE>lower</CODE>
<DD>
Prefer lower case.
Names that were subjected to upper-case substitution by SGML will be folded
to lower case.
This does not include reserved names; XML requires these to be in upper-case.
<DT>
<CODE>pi-escape</CODE>
<DD>
Escape <CODE>&amp;&lt;&gt;</CODE> in the contents of processing
instructions using the <CODE>amp</CODE>, <CODE>lt</CODE> and
<CODE>gt</CODE> entities.  This allows processing instructions to
contain the string <CODE>&gt;?</CODE>, but requires that applications
handle the escapes.
<DT>
<CODE>empty</CODE>
<DD>
Use the <CODE>&lt;<VAR>e</VAR>/&gt;</CODE> syntax for element types
<CODE><VAR>e</VAR></CODE> declared as EMPTY.
<DT>
<CODE>attlist</CODE>
<DD>
Output a ATTLIST declaration for every element specifying the type of
all attributes.  The default will always be <CODE>#IMPLIED</CODE>.
</DL>
<P>
Multiple
<CODE>-x</CODE>
options are allowed.
</DL>
<P>
<ADDRESS>
James Clark<BR>
jjc@jclark.com
</ADDRESS>
</BODY>
</HTML>
